From: Claudio Cambra Date: Wed, 22 Mar 2023 13:53:06 +0000 (+0100) Subject: Emit AccountPtr from pushNotificationsDisabled in Account rather than raw pointer X-Git-Tag: archive/raspbian/3.16.7-1_deb13u1+rpi1~1^2~12^2^2~26^2~5 X-Git-Url: https://dgit.raspbian.org/%22http:/www.example.com/cgi/%22https://%22Program/%22http:/www.example.com/cgi/%22https:/%22Program?a=commitdiff_plain;h=df6ec7baaa4b5069f2e127a0036f877a54dde091;p=nextcloud-desktop.git Emit AccountPtr from pushNotificationsDisabled in Account rather than raw pointer Signed-off-by: Claudio Cambra --- diff --git a/src/libsync/account.cpp b/src/libsync/account.cpp index cf59af7d5..5acb7897b 100644 --- a/src/libsync/account.cpp +++ b/src/libsync/account.cpp @@ -341,7 +341,7 @@ void Account::trySetupPushNotifications() return; } if (!_pushNotifications->isReady()) { - emit pushNotificationsDisabled(this); + emit pushNotificationsDisabled(sharedFromThis()); } if (!_pushNotificationsReconnectTimer.isActive()) { _pushNotificationsReconnectTimer.start(); diff --git a/src/libsync/account.h b/src/libsync/account.h index ae119758f..5e6c67318 100644 --- a/src/libsync/account.h +++ b/src/libsync/account.h @@ -461,7 +461,7 @@ signals: void appPasswordRetrieved(QString); void pushNotificationsReady(const OCC::AccountPtr &account); - void pushNotificationsDisabled(OCC::Account *account); + void pushNotificationsDisabled(const OCC::AccountPtr &account); void userStatusChanged();